﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/Admin.Master" AutoEventWireup="true" CodeBehind="sanpham.aspx.cs" Inherits="UI.Admin.sanpham" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
        <style type="text/css">
        .style5
        {
            height: 95px;
            width: 674px;
        }
        .style6
        {
            /*height: 250px;*/
            width: 785px;
        }
        .style7
        {
            height: 117px;
            width: 674px;
        }
            .auto-style1 {
                width: 409px;
            }
            .auto-style2 {
                height: 15px;
                width: 273px;
            }
            .auto-style3 {
                height: 15px;
                width: 202px;
            }
    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <table align="center" border="0" cellpadding="0" cellspacing="0" 
        style="width: 976px">
        <tr>
            <td class="style6">
                <asp:MultiView ID="MultiView1" runat="server">
                    <asp:View ID="View1" runat="server">
                        <table align="center" border="0" cellpadding="5" cellspacing="5" 
                            style="width: 722px">

                            <tr>
                                <td class="style5">
                                    <table>
                                        <tr>
                                            <td style="width: 170px">
                                                Tìm Kiếm Nhà Xuất Bản:
                                            </td>
                                            <td align="center" style="width; 300px">
                                                <asp:TextBox ID="txttim" Width="250px" runat="server"></asp:TextBox>
                                            </td>
                                            <td style="width: 200px">
                                                <asp:Button ID="btntmkiem" runat="server" BackColor="#A52B2B" ForeColor="White" Text="Tìm Kiếm" OnClick="btntmkiem_Click"
                                                    Style="height: 26px" />
                                                <asp:Button ID="Button1" runat="server" BackColor="#A52B2B" ForeColor="White" onclick="Button1_Click" Text="Trở về" />
                                            </td>
                                        </tr>
                                        <tr>
                                            <td colspan="3" align="center">
                                                <asp:Button ID="btntaomoi" runat="server" Text="Thêm Nhà Xuất Bản" BackColor="#A52B2B" ForeColor="White" OnClick="btntaomoi_Click" />
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td align="center" class="style7">
                                    <br />
                                    <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" CellPadding="4"
                                        ForeColor="Black" OnPageIndexChanging="GridView1_PageIndexChanging"
                                        OnSelectedIndexChanged="GridView1_SelectedIndexChanged" AllowPaging="True" PageSize="5"
                                        OnRowDeleting="GridView1_RowDeleting" BackColor="White" 
                                        BorderColor="#CCCCCC" BorderStyle="Dotted" BorderWidth="1px" Width="960px">
                                        <Columns>
                                            <asp:CommandField ShowSelectButton="True" HeaderText="Chọn sản phẩm" />
                                            <asp:CommandField ShowDeleteButton="True" HeaderText="Xóa sản phẩm" />
                                            <asp:BoundField DataField="MaSP" HeaderText="Mã sản phẩm" />
                                            <asp:BoundField DataField="MaNSX" HeaderText="mã nhà sản xuất" />
                                            
                                            <asp:BoundField DataField="TenSP" HeaderText="tên sản phẩm" />
                                            <asp:BoundField DataField="DonGia" HeaderText="đơn giá" />
                                            <asp:BoundField DataField="SoLuong" HeaderText="số lượng" />
                                           <asp:BoundField DataField="NgaySX" HeaderText="ngày sản xuất" />
                                            <asp:BoundField DataField="NgayCapNhat" HeaderText="ngày cập nhật" />
                                            <asp:BoundField DataField="SoLuongDaBan" HeaderText="số lượng bán" />
                                            <asp:BoundField DataField="SoLanXem" HeaderText="số lần xem" />

                                           
                                            
                                        </Columns>
                                        <EmptyDataTemplate>
                                            Nhà Xuất Bản Không Tồn Tại !
                                        </EmptyDataTemplate>
                                        <FooterStyle BackColor="#CCCC99" ForeColor="Black" />
                                        <HeaderStyle BackColor="#333333" Font-Bold="True" ForeColor="White" />
                                        <PagerStyle BackColor="White" ForeColor="Black" HorizontalAlign="Right" />
                                        <SelectedRowStyle BackColor="#CC3333" Font-Bold="True" ForeColor="White" />
                                        <SortedAscendingCellStyle BackColor="#F7F7F7" />
                                        <SortedAscendingHeaderStyle BackColor="#4B4B4B" />
                                        <SortedDescendingCellStyle BackColor="#E5E5E5" />
                                        <SortedDescendingHeaderStyle BackColor="#242121" />
                                    </asp:GridView>
                                </td>
                            </tr>
                            
                        </table>
                    </asp:View>
                    <asp:View ID="VIew2" runat="server">
                        <table cellpadding="5" cellspacing="5" style="width: 970px">
                            <tr>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style2">
                                    Mã Sản Phẩm:
                                </td>
                                <td align="left" class="auto-style1">
                                    <asp:Label ID="lbmasp" runat="server" Text="Label"></asp:Label>
                                </td>
                                 <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style3">
                                     Hệ Điều Hành:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtHDH" Width="286px" runat="server" style="margin-left: 0px"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style2">
                                    Mã Nhà Sản Xuất:
                                </td>
                                <td align="left" class="auto-style1">
                                    <asp:DropDownList ID="txtMaNSX" runat="server" Height="16px" Width="231px">
                                    </asp:DropDownList>
                                </td>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style3">
                                    Màn Hình:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtManHinh" Width="286px" runat="server" style="margin-left: 0px"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style2">
                                    Tên Tên Sản Phẩm:
                                </td>
                                <td align="left" class="auto-style1">
                                    <asp:TextBox ID="txttensp" Width="221px" runat="server"></asp:TextBox>
                                </td>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style3">
                                    Camera Trước:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtcameratruoc" Width="286px" runat="server" style="margin-left: 0px"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style2">
                                    Đơn Giá:</td>
                                <td align="left" class="auto-style1">
                                    <asp:TextBox ID="txtdongia" Width="220px" runat="server" TextMode="MultiLine"></asp:TextBox></td>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style3">
                                    Camera Sau:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtcamerasau" Width="286px" runat="server" style="margin-left: 0px"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style2">
                                    Số Lượng:</td>
                                <td align="left" class="auto-style1">
                                    <asp:TextBox ID="txtsoluong" Width="214px" runat="server"></asp:TextBox></td>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style3">
                                    CPU:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtcpu" Width="286px" runat="server" style="margin-left: 0px"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style2">
                                    Ngày Sản Xuất:</td>
                                <td align="left" class="auto-style1">
                                    <asp:TextBox ID="txtngaysx" Width="212px" runat="server"></asp:TextBox></td>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style3">
                                    Ram:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtRam" Width="286px" runat="server" style="margin-left: 0px"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style2">
                                    Ngày Cập Nhật:</td>
                                <td align="left" class="auto-style1">
                                    <asp:TextBox ID="txtngaycapnhat" Width="208px" runat="server"></asp:TextBox></td>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style3">
                                    Rom:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtRom" Width="286px" runat="server" style="margin-left: 0px"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td align="right" 
                                    style="font-weight: bold; font-size: 15px" class="auto-style2">
                                    Logo Nhà Xuất Bản:</td>
                                    
                                <td align="left" class="auto-style1">
                                
                                    <asp:ScriptManager ID="ScriptManager1" runat="server">
                                    </asp:ScriptManager>

                                    <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional">
                                    
                                     <ContentTemplate>
                                     <div>
                                    <asp:Image ID="Image2" runat="server" Height="109px" Width="115px" />
                                <asp:FileUpload ID="FileUpload2" runat="server" Height="25px" style="margin-left: 44px" Width="81px" />

                                 
                                   </div>
                                </ContentTemplate>
                                    </asp:UpdatePanel>

                              
                                    
                                    </td>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style3">
                                    DL Pin:
                                </td>
                                <td style="width: 450px" align="left">
                                    <asp:TextBox ID="txtDLPin" Width="286px" runat="server" style="margin-left: 0px"></asp:TextBox>
                                </td>
                                   
                            </tr>


                           
                            <tr>
                                <td style="font-weight: bold; font-size: 15px" align="right" class="auto-style2">
                                </td>
                                <td align="left" class="auto-style1">
                                    <asp:Button ID="btninsert" Width="60px" runat="server"  BackColor="#A52B2B" ForeColor="White" Text="Insert" Enabled="False"
                                        OnClick="btninsert_Click" ValidationGroup="hang" />
                                    <asp:Button ID="btnupdate" runat="server"  BackColor="#A52B2B" ForeColor="White" Width="60px" Text="Update" OnClick="btnupdate_Click"
                                        ValidationGroup="hang" />
                                        <asp:Button ID="btnback" runat="server" BackColor="#A52B2B" ForeColor="White" Width="74px" Text="Trở Về" OnClick="btnback_Click" />
                                          
                                   
                                </td>
                            </tr>
                        </table>
                    </asp:View>
                </asp:MultiView>
            </td>
        </tr>
    </table>
</asp:Content>
